BaseList
Ecng.Collections
Represents a base class for a strongly-typed list of items.
継承元: BaseCollection<T, IList<T>>
コンストラクター
BaseList
protected BaseList(IList<TItem> innerList)
baseList = BaseList(innerList)
Represents a base class for a strongly-typed list of items.
BaseList
protected BaseList()
baseList = BaseList()
Initializes a new instance of the BaseList class with an empty inner list.
メソッド
IndexOf
public override int IndexOf(TItem item)
result = baseList.IndexOf(item)
Determines the index of a specific item in the inner list.
- item
- The item to locate in the list.
戻り値: The index of the item if found in the list; otherwise, -1.
OnGetItem
protected override TItem OnGetItem(int index)
result = baseList.OnGetItem(index)
Retrieves the item at the specified index from the inner list.
- index
- The zero-based index of the item to retrieve.
戻り値: The item at the specified index.
OnInsert
protected override void OnInsert(int index, TItem item)
baseList.OnInsert(index, item)
Inserts an item into the inner list at the specified index.
- index
- The zero-based index at which the item should be inserted.
- item
- The item to insert into the list.
OnRemoveAt
protected override void OnRemoveAt(int index)
baseList.OnRemoveAt(index)
Removes the item at the specified index from the inner list.
- index
- The zero-based index of the item to remove.